Focusing device and method

ABSTRACT

An automatic focus adjustment device has an image sensing element for converting an object optical image into an electrical signal, and outputting an image signal, a filter for extracting high-frequency components of the image signal obtained by the image sensing element, an integrator for integrating the high-frequency components extracted by the filter and outputting an integrated value, a peak hold circuit for detecting and outputting a peak value of the high-frequency components extracted by the filter, a discrimination unit for discriminating the luminance distribution of the object optical image, and a focus adjustment unit for making focus adjustment using one of the integrated value output from the integrator and the peak value output from the peak hold circuit in accordance with the discrimination result.

This application is a divisional of application Ser. No. 09/649,951,filed Aug. 29, 2000, now U.S. Pat. No. 6,972,798.

FIELD OF THE INVENTION

The present invention relates to a focusing device and method and, moreparticularly, to a focusing device and method, which are used in animage sensing apparatus such as a video camera, digital still camera, orthe like, for setting an appropriate in-focus state.

BACKGROUND OF THE INVENTION

As a conventional automatic focus adjustment operation used in a videoequipment such as a video camera or the like, a so-called “hill-climbingoperation” is known. In this operation, a high-frequency component in animage signal obtained from an image sensing element such as a CCD isextracted, and focus adjustment is done by driving a focusing lens tomaximize the high-frequency component. Since the focus adjustment systembased on this “hill-climbing operation” makes focus detection based onthe sharpness of an object image, it can accurately adjust the focusirrespective of the object distance, i.e., even when an object islocated at a far or closest distance position.

As conventional auto-focusing (to be abbreviated to “AF” hereinafter)based on the hill-climbing operation, an integration AF method thatintegrates, within a predetermined distance measurement range of aframe, image signal components which have undergone a high-pass filterprocess for extracting a high-frequency component and uses an integratedsignal in focusing control is prevalently used. Since the integration AFmethod integrates extracted high-frequency components within thedistance measurement range and uses the integrated signal, it isexcellent in AF stability, and can easily obtain an optimal in-focuspoint.

FIG. 14 is a block diagram showing an arrangement of a video camerasystem adopting the conventional integration AF method.

Referring to FIG. 14, reference numeral 101 denotes a stationary firstlens group; 102, a zoom lens for zooming; 103, an iris for adjusting thequantity of light; and 104, a stationary second lens group. Referencenumeral 105 denotes a focus compensation lens (to be referred to as a“focus lens” hereinafter) which has a function of compensating formovement of a focal plane upon zooming, and a focus adjustment function.

Reference numeral 106 denotes a CCD as an image sensing element.Reference numeral 107 denotes a CDS/AGC which performs sample-and-holdoperation and amplifies the output from the CCD 106, and the gain ofwhich is adjusted by a signal from a camera controller (microcomputer)114 to be described later. Reference numeral 108 denotes an A/Dconverter for converting an analog signal from the CDS/AGC 107 into adigital signal; and 109, a camera signal processing circuit. The outputsignal from the camera signal processing circuit 109 is recorded on arecording medium such as a magnetic tape, memory, or the like (notshown).

Reference numeral 110 denotes a timing signal generator for supplyingvarious drive pulses and timing pulses to the respective sections of thecamera, such as the CCD 106, CDS/AGC 107, and the like.

Reference numeral 111 denotes a zoom lens driver for driving the zoomlens 102; 112, an iris driver for driving the iris 103; and 113, a focuslens driver for driving the focus lens 105. The drivers 111 to 113respectively drive motors included therein in accordance with signalsfrom the camera controller 114.

Reference numeral 120 denotes a focus evaluation value processor, whichhas a high-pass filter 121 for extracting a predetermined high-frequencycomponent from a luminance signal output from the A/D converter 108, adistance measurement range gate 122 for extracting only signalcomponents within a predetermined distance measurement range from aframe, a line peak hold circuit 123 for holding peaks of the signalcomponents extracted by the distance measurement range gate 122 in unitsof horizontal scan lines, and an integrator 124 for integrating peakvalues of the peak-held scan lines. The integrated value is called an“integrated focus evaluation value”.

The value of the integrator 124 is reset for each frame, and theintegrator 124 can compute the integrated focus evaluation value foreach frame. The integrated focus evaluation value is input to the cameracontroller 114, which drives the focus lens 105 via the focus lensdriver 113 to maximize the integrated focus evaluation value.

In the prior art, the peak values of the peak-held scan lines areintegrated. Alternatively, the signal components may be integratedwithout holding peaks, or peak values may be held in units of aplurality of horizontal scan lines, and the held values may beintegrated.

The output luminance signal from the A/D converter 108 is also input toan exposure evaluation value processor 130, which generates anevaluation value for controlling exposure from signal components of aframe and supplies it to the camera controller 114. The cameracontroller 114 drives the iris 103 based on the exposure evaluationvalue to obtain an optimal exposure value. A key unit 115 is connectedto the camera controller 114, and various kinds of key operationinformation of the camera unit such as a zoom key for operating the zoomlens 102 and the like are output to the camera controller 114. Forexample, when the user has pressed the zoom key, the camera controller114 drives the zoom lens 102 via the zoom lens driver 111 to obtain adesired zoom ratio (focal length).

However, since the integration AF method controls to obtain the highestaverage contrast within a frame, although no problem is posed for anormal object focusing performance impairs for an image of ahigh-luminance object or a point light source in a night scene (to bereferred to as a “peak image” hereinafter).

FIG. 15 shows an example of the integrated focus evaluation value of anormal object, and FIG. 16 shows an example of the integrated focusevaluation value of a peak image. In the normal object, since anin-focus point and a peak value of the integrated focus evaluation valueappear at an identical position P0, as shown in FIG. 15, and no problemis posed. However, in the peak image, an in-focus point and a peak ofthe integrated focus evaluation value do not appear at the sameposition, and the peak of the integrated focus evaluation value appearsat a slightly offset focus lens position PB, as shown in FIG. 16.

In case of an image of a point light source in a night scene as atypical peak image, the integrated focus evaluation value assumes alarger value in an out-of-focus state shown in FIG. 18 than a perfectin-focus state shown in FIG. 17. Note that FIGS. 17 and 18 show examplesof images that appear on the frame upon sensing a peak image. In thismanner, a peak of the integrated focus evaluation value appears at afocus lens position offset from an actual in-focus point. In such case,since the camera controller 114 controls the focus lens 105 to aposition where the integrated focus evaluation value has a peak, thefocus lens 105 is controlled to the focus lens position PB shown in FIG.16. As a result, the obtained image is out of focus.

As an alternative to the integration AF method, a peak AF method thatuses a maximum peak value within a predetermined distance measurementrange from luminance signal components of a frame that has undergone ahigh-pass filter process for extracting high-frequency components isknown. FIG. 19 is a block diagram showing the arrangement of a videocamera system that adopts the conventional peak AF method.

The video camera shown in FIG. 19 has substantially the same arrangementas that of the video camera shown in FIG. 14, except that thearrangement of the focus evaluation value processor 120 is modified toobtain the maximum value of high-frequency components of the luminancesignal within the distance measurement range. Referring to FIG. 19, themaximum value of high-frequency components of the luminance signalwithin the distance measurement range, which is output from a focusevaluation value processor 1201 is called a “peak focus evaluationvalue”.

FIG. 20 shows a peak focus evaluation value in a peak image which ishard to focus upon adjustment by integration AF. For the purpose ofcomparison with integration AF, FIG. 20 also shows the integrated focusevaluation value. As can be seen from FIG. 20, the peak focus evaluationvalue becomes maximal at a correct in-focus point even in a peak image.FIGS. 21A and 21B respectively show a luminance signal for onehorizontal line of a portion indicated by LA in FIG. 17, and the outputof a high-pass filter of an in-focus image of a point light source.FIGS. 22A and 22B respectively show a luminance signal for onehorizontal line of a portion indicated by LB in FIG. 18, and the outputof a high-pass filter of an out-of-focus image of a point light source.

In this manner, even in a peak image with a saturated luminance signal,since in-focus and out-of-focus images have different leading edges ofluminance signals, the output from the high-pass filter differs incorrespondence with these images, thus allowing correct in-focus pointdetecting. In the peak AF method, a correct in-focus point can bedetected in a peak image.

However, since the peak focus evaluation value is smaller than theintegrated focus evaluation value, the peak AF method has poor stabilityfor a normal object compared to the integration AF method, and AF oftenbecomes unstable under the influence of, e.g., panning.

Since it is controlled to obtain the highest average contrast within aframe in the integration AF method, no problem is posed in a normalobject, but focusing performance impairs in a peak image.

SUMMARY OF THE INVENTION

The present invention has been made in consideration of the abovesituation, and has as its object to provide an automatic focusadjustment device and method which can accurately detect an in-focuspoint for not only a normal image but also a peak image.

According to the present invention, the foregoing object is attained byproviding an apparatus comprising: (A) a photo-receiving device forreceiving light from an object and converting it into an electricalsignal; and (B) a focus adjusting device for forming a first adjustmentsignal by performing a predetermined integration operation on apredetermined frequency component of an image signal obtained by thephoto-receiving device and forming a second focus adjustment signal,different from the first focus adjustment signal, from a peak value of apredetermined frequency component of the image signal obtained by thephoto-receiving device, wherein the focus adjustment apparatus appliesat least one of the first and second focus adjustment signals to focusadjustment on the basis of a luminous state of the object.

Further, the foregoing object is also attained by providing an apparatuscomprising: (A) a photo-receiving device for receiving light from anobject; and (B) a focus adjusting device performing an operation forfocus adjustment, wherein the focus adjusting device performs theoperation depending upon determination whether or not an object imagehas a luminous state judged as a peak image from a photo-received signalon the basis of the photo-receiving device.

Furthermore, the foregoing object is also attained by providing a focusadjusting method comprising: converting light from an object into animage signal, forming a first adjustment signal by performing apredetermined integration operation on a predetermined frequencycomponent of the image signal, forming a second focus adjustment signal,different from the first focus adjustment signal, from a peak value of apredetermined frequency component of the image signal, applying at leastone of the first and second focus adjustment signal to focus adjustmenton the basis of a luminous state of the object.

Further, foregoing object is also attained by providing a focusadjusting method comprising: performing an operation for focusadjustment depending upon determination whether or not an object imagehas a luminous state judged as a peak image on the basis of aphoto-received signal of light of the object.

Further, foregoing object is also attained by providing a computerprogram product comprising: converting light from an object into animage signal, forming a first adjustment signal by performing apredetermined integration operation on a predetermined frequencycomponent of the image signal, forming a second focus adjustment signal,different from the first focus adjustment signal, from a peak value of apredetermined frequency component of the image signal, applying at leastone of the first and second focus adjustment signal to focus adjustmenton the basis of a luminous state of the object.

Further, foregoing object is also attained by A computer program productcomprising: performing an operation for focus adjustment depending upondetermination whether or not an object image has a luminous state judgedas a peak image on the basis of a photo-received signal of light of theobject.

Other features and advantages of the present invention will be apparentfrom the following description taken in conjunction with theaccompanying drawings, in which like reference characters designate thesame or similar parts throughout the figures thereof.

BRIEF DESCRIPTION OF THE DRAWINGS

The accompanying drawings, which are incorporated in and constitute apart of the specification, illustrate embodiments of the invention and,together with the description, serve to explain the principles of theinvention.

FIG. 1 is a block diagram showing an arrangement of a video camerasystem that adopts a focus adjustment method according to a firstembodiment of the present invention;

FIG. 2 is a flow chart showing a focus adjustment control sequenceexecuted by a camera controller according to the first embodiment of thepresent invention;

FIG. 3 is a graph for explaining a peak image discrimination schemeaccording to the first embodiment of the present invention;

FIG. 4 is a flow chart showing a focus adjustment control sequenceaccording to the second embodiment of the present invention;

FIG. 5 is a graph for explaining a peak image discrimination schemeaccording to the second embodiment of the present invention;

FIG. 6 is a flow chart showing a focus adjustment control sequenceaccording to the third embodiment of the present invention;

FIG. 7 is a graph for explaining a peak image discrimination schemeaccording to the third embodiment of the present invention;

FIG. 8 is a block diagram showing an arrangement of a video camerasystem that adopts a focus adjustment method according to the fourthembodiment of the present invention;

FIG. 9 is a graph showing the relationship between the field depth andintegrated focus evaluation value in a peak image;

FIG. 10 is a flow chart showing a focus adjustment control sequenceaccording to the fourth embodiment of the present invention;

FIG. 11 is graph for explaining a peak image discrimination schemeaccording to the fourth embodiment of the present invention;

FIG. 12 is a flow chart showing a focus adjustment control sequenceaccording to the fifth embodiment of the present invention;

FIGS. 13A and 13B are graphs for explaining a peak image discriminationscheme according to the fifth embodiment of the present invention;

FIG. 14 is a block diagram showing an arrangement of a video camerasystem that adopts the conventional integration AF method;

FIG. 15 is a graph showing an example of an integrated focus evaluationvalue in a normal object;

FIG. 16 is a graph showing an example of an integrated focus evaluationvalue in a peak image;

FIG. 17 is a view showing an example of an image that appears on a frameupon sensing a peak image;

FIG. 18 is a view showing an example of an image that appears on a frameupon sensing a peak image;

FIG. 19 is a block diagram showing an arrangement of a video camerasystem that adopts the conventional peak AF method;

FIG. 20 is a graph showing an example of a peak focus evaluation valuein a peak image;

FIGS. 21A and 21B are graphs respectively showing the luminance signalfor one horizontal line, and the output from a high-pass filter; and

FIGS. 22A and 22B are graphs respectively showing the luminance signalfor one horizontal line, and the output from a high-pass filter.

DETAILED DESCRIPTION OF THE PREFERRED EMBODIMENTS

Preferred embodiments of the present invention will be described indetail in accordance with the accompanying drawings.

[First Embodiment]

The first embodiment of the present invention will be described firstwith reference to FIGS. 1 to 3.

FIG. 1 is a block diagram showing an arrangement of a video camerasystem that adopts a focus adjustment method according to the firstembodiment. The same reference numeral in FIG. 1 denote the same partsas in the arrangement of the conventional video camera system shown inFIG. 14, and a detailed description thereof will be omitted. Acharacteristic feature of the video camera system in the firstembodiment lies in operations of a focus evaluation value processor 220capable of outputting an integrated focus evaluation value and peakfocus evaluation value, an exposure evaluation value processor 230capable of outputting the average and peak luminance values of a frame,and a camera controller 240 which receives these values.

A luminance signal which is output from an A/D converter 108 and inputto the focus evaluation value processor 220 undergoes a process forextracting a predetermined high-frequency component from the luminancesignal by a high-pass filter 221. Then, a distance measurement rangegate 222 executes a process for extracting only signal components withina predetermined distance measurement range from a frame. A line peakhold circuit 223 holds peaks of the extracted signal components in unitsof horizontal scan lines. An integrator 224 integrates peak values inunits of scan lines within the distance measurement range, and outputsan integrated focus evaluation value. The output from the distancemeasurement range gate 222 is also input to a peak hold circuit 225 toextract the maximum high-frequency component within the distancemeasurement range. This value is called a peak focus evaluation value.The values of the integrator and peak hold circuit are reset for eachframe, and the integrated focus evaluation value and peak focusevaluation value for each frame can be output to the camera controller240.

The exposure evaluation value processor 230 executes a process forextracting only a signal within a predetermined photometry range from aframe using a photometry range gate 231 with respect to the luminancesignal input from the A/D converter 108. The luminance signal extractedby the photometry range gate 231 is input to an integrator 232, whichoutputs an average luminance signal obtained by summing up and averagingluminance signal components in the photometry range to the cameracontroller 240. Also, the luminance signal extracted by the photometryrange gate 231 is input to a peak hold circuit 233, which outputs amaximum luminance signal within the photometry range to the cameracontroller 240.

FIG. 2 is a flow chart showing the AF focus adjustment control sequenceexecuted by the camera controller 240 using these input signals.

An average luminance value Yavr and peak luminance value Ypeak are read(step S200), and it is checked if the peak luminance value Ypeak ishigher than a predetermined value Yth1 (step S201). If the peakluminance value Ypeak is lower than the predetermined value Yth1, theobject is unlikely to be a high-luminance object or point light source,and it is determined that the object is a normal image. Hence, a processfor reading the integrated focus evaluation value output from theintegrator 224 is executed (step S210).

On the other hand, if it is determined in step S201 that the peakluminance value Ypeak is higher than the predetermined value Yth1, it ischecked if the average luminance value Yavr output from the integrator232 is very low, i.e., if the average luminance value Yavr is lower thana predetermined value Yth2 (step S202). If average luminance value Yavris lower than the predetermined value Yth2, since it is determined thatthe object is a peak image (night scene or the like), a process forreading a peak focus evaluation value output from the peak hold circuit225 is executed (step S220). FIG. 3 is an explanatory view showing anexample of a peak image discrimination scheme based on the averageluminance value Yavr and peak luminance value Ypeak. A condition thatthe peak luminance value Ypeak is not low in step S201 and the averageluminance value Yavr is very low in step S202 corresponds to region 1shown in FIG. 3.

If it is determined in step S202 that the average luminance value Yavris not lower than the predetermined value Yth2, it is checked if thepeak luminance value Ypeak is very high, i.e., it is higher than apredetermined value Yth3 (Yth3>Yth1) (step S203). If the peak luminancevalue Ypeak is higher than the predetermined value Yth3, it is checkedif the average luminance value Yavr is lower than a predetermined valueYth4 (Yth4>Yth2) (step S204).

If it is determined in step S204 that the average luminance value Yavris lower than the predetermined value Yth4, i.e., if the peak luminancevalue Ypeak is very high and the average luminance value Yavr is low tosome extent, it is determined that the object is a peak image such as animage of sunbeams coming through branches of trees or the like, and theprocess for reading a peak focus evaluation value is executed in stepS220. This condition corresponds to region 2 shown in FIG. 3.

When the object does not satisfy the condition of region 1 or 2, i.e.,if the peak luminance value Ypeak is low (NO in step S201 or S203) orboth the average luminance value Yavr and peak luminance value Ypeak arehigh (NO in step S204), it is determined that the object is a normalimage, and the process for reading the integrated focus evaluation valueis executed in step S210. The condition of the normal image correspondsto region 3 in FIG. 3.

It is checked based on the average luminance value Yavr and peakluminance value Ypeak in the aforementioned sequence if the object is apeak or normal image. If it is determined that the object is a normalimage, an AF process is done using the integrated focus evaluationvalue; otherwise, an AF process is done using a peak focus evaluationvalue (step S230).

In this manner, in case of an object such as a night scene, point lightsource, or the like (peak image) that poses a problem in theconventional integration AF method, correct focus adjustment control canbe done using the peak focus evaluation value. In case of a normalimage, since focus adjustment control is done based on the integratedfocus evaluation value, stable focus adjustment can be made.

Since an object is discriminated in this manner, and AF control optimalto each object is done, a system which has merits of both theintegration and peak AF methods can be implemented. That is, accordingto the first embodiment, correct focus adjustment can be done not onlyin a normal image but also in a peak image.

[Second Embodiment]

The second embodiment of the present invention will be described belowwith reference to FIGS. 4 and 5.

The second embodiment is characterized in that a peak image isdiscriminated based on a luminance signal using a scheme different fromthat in the first embodiment.

FIG. 4 is a flow chart showing the focus adjustment control sequenceaccording to the second embodiment of the present invention, and FIG. 5is an explanatory view showing the peak image discrimination scheme. InFIG. 4, the sequence in step S200 and steps S210 to S230 is the same asthose in FIG. 2.

An average luminance value Yavr and peak luminance value Ypeak are readin step S200, and it is checked in step S201B if the peak luminancevalue Ypeak and average luminance value Yavr satisfy:Ypeak>K 1×Yavr+Yth 5  (1)where the coefficient K1 is the ratio between the peak luminance valueYpeak and average luminance value Yavr, and corresponds to the slope ofa straight line L1 in FIG. 5. Also, the predetermined value Yth5 is anoffset of the straight line L1, and corresponds to Yth5 in FIG. 5. Inthe second embodiment, if the peak luminance value is expressed by 8-bitdata, since the maximum level is 255, the slope K1 is given by:K 1=(255−Yth 5)/Yth 6  (2)The relationship that satisfies this condition corresponds to a peakimage region shown in FIG. 5. An object within this region undergoes anAF process using a peak focus evaluation value. On the other hand, ifthis condition is not satisfied, it is determined that the object is anormal image, and an AF process is done using an integrated focusevaluation value.

As described above, according to the second embodiment, since the peakfocus evaluation value is used in focus adjustment control for an objectsuch as a night scene, point light source, or the like (peak image) thatposes a problem in the conventional integration AF method, accuratefocus adjustment is done even in a peak image. Since the integratedfocus evaluation value is used in focus adjustment control for a normalimage, stable focus adjustment can be assured.

[Third Embodiment]

The third embodiment of the present invention will be described belowwith reference to FIGS. 6 and 7.

The third embodiment is characterized in that a peak image isdiscriminated based on a luminance signal using a scheme different fromthat in the first and second embodiments.

The third embodiment uses the ratio between the average luminance valueYavr and peak luminance value Ypeak and offset as conditions as in thesecond embodiment, but is different from the scheme of the secondembodiment in that a plurality of ratios are used.

FIG. 6 is a flow chart showing the focus adjustment control sequenceaccording to this embodiment, and FIG. 7 is an explanatory view showingthe peak image discrimination method. Step S200 and steps S210 to S230in FIG. 6 are the same as those shown in FIG. 2 explained in the firstembodiment.

When an average luminance value Yavr and peak luminance value Ypeak areread, it is checked if these average luminance value Yavr and peakluminance value Ypeak satisfy a first condition:Ypeak>K 2×Yavr+Yth 7  (3)that is, if luminance data falls within a peak image region shown inFIG. 7 (step S201C). In inequality (3), the coefficient K2 is the ratiobetween the average luminance value Yavr and peak luminance value Ypeak,and corresponds to the slope of a straight line L2 in FIG. 7. Also, thepredetermined value Yth7 corresponds to an offset of the straight lineL2 shown in FIG. 7. In the third embodiment, if the peak luminance valueYpeak is expressed by 8-bit data, since the maximum level is 255, theslope K2 is given by:K 2=(255−Yth 7)/Yth 8  (4)If it is determined in step S201C that the luminance data fall withinthe peak image region that satisfies inequality (3), a peak focusevaluation value is read in step S220, and an AF process is executed instep S230.

On the other hand, if it is determined in step S201C that the luminancedata do not satisfy inequality (3), it is checked in step S202C if theluminance data satisfy a second condition:Ypeak>K 3×Yavr+Yth 9  (5)where the coefficient K3 is the ratio between the average luminancevalue Yavr and luminance peak value Ypeak, and corresponds to the slopeof a straight line L3 in FIG. 7. Also, the predetermined value Yth9corresponds to an offset of the straight line L3 shown in FIG. 7. In thethird embodiment, if the peak luminance value Ypeak is expressed by8-bit data, since the maximum level is 255, the slope K3 is given by:K 3=(255−Yth 9)/Yth 10  (6)If this second condition is satisfied, it is also determined that theobject is a peak image. A peak focus evaluation value is read in stepS220, and an AF process is done using the peak focus evaluation value instep S230. If the second condition is not satisfied either, it isdetermined that the object is a normal image. An integrated focusevaluation value is read in step S210, and an AF process is done usingthe integrated focus evaluation value.

As described above, according to the third embodiment, since the peakfocus evaluation value is used in focus adjustment control for anobject, such as a night scene, point light source, or the like (peakimage) that poses a problem in the conventional integration AF method,since the peak focus evaluation value is used in focus adjustmentcontrol, accurate focus adjustment can be done even in a peak image.Since the integrated focus evaluation value is used in focus adjustmentcontrol for a normal image, stable focus adjustment can be assured.

[Fourth Embodiment]

The fourth embodiment of the present invention will be described belowwith reference to FIGS. 8 to 11.

FIG. 8 is a block diagram showing an arrangement of a video camerasystem according to the fourth embodiment. The same reference numeralsin FIG. 8 denote the same parts as in the arrangement shown in FIG. 1,and a detailed description thereof will be omitted.

The fourth embodiment is characterized in that the output from an irisposition detector 250 for detecting the aperture value of the iris, andzoom position information (focal length information) are used in peakimage discrimination. The zoom position information can be detectedbased on a signal such as a stepping motor address for driving the zoomlens, which is output from the camera controller 240 to the zoom lensdriver 111. On the other hand, the iris position detector 250 comprisesa Hall element or the like, and outputs a voltage corresponding to theaperture value of the iris to the camera controller 240.

The reason why information of the iris and focal length is added to peakimage discrimination will be explained below.

In general, the field depth decreases with increasing focal length; thefield depth increases with decreasing focal length. On the other hand,when the iris opens, the field depth decreases; otherwise, the focaldepth increases. When the deviation of an object from the in-focusposition remains the same, the defocus level becomes large when thefield depth is shallow; the defocus level is small when the field depthis deep.

FIG. 9 shows the relationship between the field depth and integratedfocus evaluation value in a peak image. As shown in FIG. 9, even in apeak image, when the field depth is deep, a peak of the integrated focusevaluation value appears at a correct in-focus position P0.

That is, even when it is determined based on the peak luminance valueand average luminance value that the object is a peak image, if thefield depth is deep, focus adjustment can be done using the integratedfocus evaluation value, depending on the focal length and iris.

In the fourth embodiment, the output from the iris position detector 250and zoom position information (focal length information) are used inpeak image discrimination for the aforementioned reasons.

FIG. 10 is a flow chart showing the focus adjustment process sequenceaccording to the fourth embodiment.

A peak luminance value Ypeak, average luminance value Yavr, zoomposition data, and iris position data are read (step S300). It ischecked if the peak luminance value Ypeak is higher than a predeterminedvalue Yth11 (step S301).

If it is determined that the peak luminance value Ypeak is lower thanthe predetermined value Yth11, since the object is unlikely to be ahigh-luminance object or point light source, it is determined that theobject is a normal image irrespective of the iris and zoom states, and aprocess for reading an integrated focus evaluation value is executed(step S310). Then, focus adjustment is executed using the integratedfocus evaluation value (step S330). The reason why neither the iris norzoom states are considered in the result in step S301 is that suchobject with a low peak luminance value Ypeak is unlikely to be a peakimage irrespective of the zoom and iris states.

If it is determined in step S301 that the peak luminance value Ypeak ishigher than the predetermined value Yth11, it is checked if the averageluminance value Yavr is very low, i.e., if the average luminance valueis lower than a predetermined value Yth12 (step S302). If the averageluminance value Yavr is lower than the predetermined value Yth12, it isdetermined that the object is a peak image irrespective of the iris andzoom states, a peak focus evaluation value is read (step S320), andfocus adjustment is done using the peak focus evaluation value (stepS330). The reason why neither the iris nor zoom states are considered isthat the object is highly likely to be a peak image irrespective of thezoom and iris states.

If it is determined in step S302 that the average luminance value Yavris higher than the predetermined value YTh12, it is checked if the peakluminance value Ypeak is higher than a predetermined value Yth13 whichis higher than the predetermined value Yth11 (step S303), and if theaverage luminance value Yavr is lower than a predetermined value Yth14larger than the predetermined value Yth12 (step S304). If the peakluminance value Ypeak is lower than the predetermined value Yth13 or ifthe average luminance value Yavr is higher than the predetermined valueYth14, it is determined that the object is a normal image. The processfor reading an integrated focus evaluation value is executed in stepS310, and focus adjustment is done using that integrated focusevaluation value in step S330.

If the peak luminance value Ypeak is higher than the predetermined valueYth13 and the average luminance value Yavr is lower than thepredetermined value Yth14, the zoom position corresponding to the focallength is compared with a predetermined threshold value Zth1 to check ifthe zoom position (Zoom) is at the telephoto side with a long focallength (step S305). If the zoom position (Zoom) is smaller than thepredetermined value Zth1, i.e., is not at the telephoto side, theprocess for reading an integrated focus evaluation value is executed instep S310, and focus adjustment is done using that integrated focusevaluation value in step S330.

If the zoom position is at the telephoto side, it is checked if theaperture value of the iris is larger than a predetermined thresholdvalue Ith1 (step S306). If it is determined that the aperture value ofthe iris is smaller than the predetermined threshold value Ith1, theprocess for reading an integrated focus evaluation value is executed instep S310, and focus adjustment is done using that integrated focusevaluation value in step S330. On the other hand, if it is determined instep S306 that the aperture value of the iris is larger than thepredetermined threshold value Ith1, since it is determined that theobject is a peak image and the field depth is shallow, the process forreading a peak focus evaluation value is executed in step S320, andfocus adjustment is done using the peak focus evaluation value in stepS330.

FIG. 11 is an explanatory view showing the peak image discriminationscheme in the aforementioned sequence. In FIG. 11, a region with ashallow field depth, which satisfies the conditions in steps S305 andS306, corresponds to region B.

As described above, according to the fourth embodiment, since the peakfocus evaluation value is used in focus adjustment control for an objectsuch as a night scene, point light source, or the like (peak image) thatposes a problem in the conventional integration AF method, accuratefocus adjustment is done even in a peak image. Since the integratedfocus evaluation value is used in focus adjustment control for a normalimage, stable focus adjustment can be assured. Furthermore, since thefourth embodiment refers to the zoom and iris position information, anobject of a peak image, which is hard to discriminate using theintegrated focus evaluation value, can be discriminated more accurately.

[Fifth Embodiment]

The fifth embodiment of the present invention will be described belowwith reference to FIGS. 12 and 13.

The fifth embodiment is characterized in that a peak image isdiscriminated based on a luminance signal using a scheme different fromthat in the fourth embodiment.

FIG. 12 is a flow chart showing the focus adjustment control sequenceaccording to the fifth embodiment, and FIGS. 13A and 13B are explanatoryviews for explaining the peak image discrimination scheme. Theprocessing sequence in steps S300 to S304 and steps S310 to S330 in FIG.12 are the same as those in FIG. 10 explained in the fourth embodimentmentioned above.

If it is determined in step S304 that the average luminance value Yavris lower than the predetermined value Yth14, it is checked in step S307if the region of interest has a shallow field depth, i.e., if irisposition data Iris and zoom position data Zoom satisfy:Iris>K 4×Zoom+Ith 3  (7)where the coefficient K4 is the ratio between the zoom position dataZoom and iris position data Iris and corresponds to the slope of astraight line L4 shown in FIG. 13A, and Ith3 corresponds to an offset ofthe straight line L4. In the fifth embodiment, if the zoom position dataand iris data are 8-bit data, since their maximum level is 255, theslope K4 is given by:K 4=−(255−Ith 2)/(255−Zth 2)  (8)

If inequality (8) holds, it is determined that the field depth isshallow. This state corresponds to region B in FIG. 13A.

If the conditions in steps S301 to S304 are satisfied, and it isdetermined in step S307 that the field depth is shallow, since it isdetermined that the object is a peak image, a process for reading a peakfocus evaluation value is executed in step S320, and focus adjustment isdone using that peak focus evaluation value in step S330.

Even when the conditions in steps S301 to S304 are satisfied todetermine that the object is a peak image candidate, if the condition instep S307 is not satisfied, since it is determined that the object is anormal image, the process for reading the integrated focus evaluationvalue is executed in step S310, and an AF process is done using thatintegrated focus evaluation value in step S330.

As described above, according to the fifth embodiment, since the peakfocus evaluation value is used in focus adjustment control for an objectsuch as a night scene, point light source, or the like (peak image) thatposes a problem in the conventional integration AF method, accuratefocus adjustment is done even in a peak image. Also, since the fifthembodiment refers to the zoom and iris position information, an objectof a peak image, which is hard to discriminate using the integratedfocus evaluation value, can be discriminated more accurately.

Note that the field depth discrimination method is not limited to thatshown in FIG. 13A. For example, two conditions (peak image regiondiscrimination using straight lines L5 and L6) may be used, as shown inFIG. 13B.

[Other Embodiment]

Note that, in the aforesaid embodiments, signals to be used for focusadjustment are formed from a high-frequency component of image signalswithin the same area by performing two signal forming methods for focusadjustment. However, signals to be used for focus adjustment may beformed from a high frequency component of image signals in two differentareas in this invention.

Further, one of the two signals obtained by the two different signalforming methods for focus adjustment is selectively used, however, bothof the two signals may be used by applying weights on these two signals,and signals formed by 3 or more different signal forming methods forfocus adjustment may be used.

Further, in the above embodiments, the signal forming methods for focusadjustment are changed depending upon the result of photometry, however,other operations for focus adjustment, such as operation speed of lensfor focus adjustment, may be changed.

Further, another evaluation photometry methods different from thosedisclosed in the above embodiments, and another signal forming methodfor focus adjustment and focus adjustment method different from thosedisclosed in the above embodiments may be used in this invention.

Further, both of the focal length and a state of an iris are taken intoconsideration upon peak image judgement, however, one of these may betaken.

Further, software configuration and hardware configuration disclosed inthe above embodiments may be exchanged.

It should be noted that the present invention includes combinations ofthe aforesaid embodiments or technical elements disclosed therein.

Further, the present invention also includes an apparatus, formed by allor a part of the apparatuses disclosed in the embodiments of the presentinvention, which can be used either individually, with anotherapparatus, or within another apparatus.

Further, the present invention is applicable to: various types ofcameras, such as an electronic camera for sensing a moving and/or astill image, a camera using a silver-halide film, a single-lens reflexcamera, a leaf shutter camera, and a monitor camera; an image sensingapparatus other than cameras; an image reading apparatus; an opticalapparatus; and the like; an apparatus applied to cameras, an imagesensing apparatus, an image reading apparatus, an optical apparatus, andthe like; elements forming the foregoing apparatuses; control method ofthe foregoing apparatuses; and a computer program product for providingthe control method of the aforesaid processes to a computer system orapparatus (e.g., a personal computer), reading the program codes, by aCPU or MPU of the computer system or apparatus, from the storage medium,then executing the program.

In this case, the program codes read from the storage medium realize thefunctions according to the embodiments, and the storage medium storingthe program codes constitutes the invention.

Further, the storage medium, such as a floppy disk, a hard disk, anoptical disk, a magneto-optical disk, CD-ROM, CD-R, a magnetic tape, anon-volatile type memory card, and ROM can be used for providing theprogram codes.

Furthermore, besides aforesaid functions according to the aboveembodiments are realized by executing the program codes which are readby a computer, the present invention includes a case where an OS(operating system) or the like working on the computer performs a partor entire processes in accordance with designations of the program codesand realizes functions according to the above embodiments.

Furthermore, the present invention also includes a case where, after theprogram codes read from the storage medium are written in a functionexpansion card which is inserted into the computer or in a memoryprovided in a function expansion unit which is connected to thecomputer, CPU or the like contained in the function expansion card orunit performs a part or entire process in accordance with designationsof the program codes and realizes functions of the above embodiments.

The present invention is not limited to the above embodiments andvarious changes and modifications can be made within the spirit andscope of the present invention. Therefore to apprise the public of thescope of the present invention, the following claims are made.

1. An apparatus comprising: a photo-receiving device for receiving lightfrom an object; a determining device configured to determine whether anormal image or a peak image is obtained by said photo-receiving deviceon the basis of at least a peak luminance and an average luminance of apredetermined area where the peak luminance exists; and a focusadjusting device performing an operation for focus adjustment dependingupon determination by said determining device where a different focusadjusting scheme is used for each of the normal image and the peakimage.
 2. The apparatus according to claim 1, wherein said focusadjusting device forms a signal for the focus adjustment on the basis ofthe photo-received signal from said photo-receiving device.
 3. Theapparatus according to claim 2, wherein said focus adjusting deviceforms a signal for the focus adjustment by detecting sharpness of anobject image.
 4. The apparatus according to claim 1, wherein said focusadjusting device forms a signal for the focus adjustment by detectingsharpness of an object image.
 5. The apparatus according to claim 1,wherein said apparatus comprises an image sensing apparatus.
 6. Theapparatus according to claim 1, wherein said apparatus comprises acamera.
 7. The apparatus according to claim 1, wherein said apparatuscomprises an optical device.
 8. A focus adjusting method comprising:receiving light from an object using a photo-receiving device;determining whether a normal image or a peak image is obtained by saidphoto-receiving device on the basis of at least a peak luminance and anaverage luminance of a predetermined area where the peak luminanceexists; and performing a focus adjusting operation for focus adjustmentdepending upon determination at said determining step where a differentfocus adjusting scheme is used for each of the normal image and the peakimage.
 9. A computer program product comprising code that, whenexecuted, causes a computer to carry out the steps of: receiving lightfrom an object using a photo-receiving device; determining whether anormal image or a peak image is obtained by said photo-receiving deviceon the basis of at least a peak luminance and an average luminance of apredetermined area where the peak luminance exists; and performing afocus adjusting operation for focus adjustment depending upondetermination at said determining step where a different focus adjustingscheme is used for each of the normal image and the peak image.
 10. Thecomputer program product according to claim 9, wherein said computerprogram product comprises a storage medium.